<%@ page language="java" pageEncoding="UTF-8"%>
<%@include file="/views/common/include/taglib.jsp"%>
	<script
		src="${ctx}/js/controllers/news/yellowpage/YellowPageListController.js"
		type="text/javascript">
	</script>
	<style>
		.star{
			color: #709DCA;
    		font-family: -webkit-pictograph;
    		margin-left: 5px;
    		margin-right: 5px;
		}
	</style>
	<div style="top:130px;position:fixed;height:30px;font-size: 14px; font-family: '微软雅黑';margin-left:-236px;">
		当前位置：${sessionScope.currcent_position}
	</div>
<section style="margin-top:24px;font-family: '微软雅黑';">
	<!--begin 搜索栏 -->
	<div style="float : left;">
		<div class="forword_area"></div>
		<div class="location">便民黄页</div>
		<input id="pageName" type="text" maxlength="20" style="border:1px solid #FFAA00; width:445px ; height:34px ; margin-left: 15px; text-indent:20px; font-size: 14px; color: #C3C3C3;" placeholder="请输入关键字" value="${(not empty pageName)? pageName : ''  }">
	</div>
    <div class="search" onclick="getYellowPageList();" ><img src="${ctx }/images/seller/goods/search.png" style="margin-left:18px;margin-top:5px;"></div>
		
	<!--end 搜索栏 -->

	<div style="padding-top:50px;color: #262535;font-size: 14px;width:99.9%;">
		<table style="border:1px #E6E6E6; border-style: none none none solid; ">
			<thead>
			<tr>
			<c:if test="${fn:length(yellowPage.list)-1 < 12}"> 
			<c:if test="${fn:length(yellowPage.list) != 0}">
				<c:forEach begin="0" end="${fn:length(yellowPage.list)-1 }" var="i" >
				    <c:set var="item" value="${(yellowPage.list)[i]}"/>
				   		<td style="float:left; width:33% ;height:185px;"> 
							<div style="border:1px #E6E6E6;border-style: solid solid solid none; width:100% ; height:100%;">
								<div style="float:left; padding-left:20px;padding-top:30px;"><img src="${ctx }/images/seller/news/logo.png"></div>
								<c:if test="${empty(item.phone1)}">
									<div style="padding-top:27px;margin-left:115px;"><em class="star">* </em>${item.pageName}</div>
									<div style="float:left;margin-top:10px;margin-left:36px; "><img src="${ctx }/images/seller/news/phone.png"></div>
									<div style="margin-top:10px;margin-left:145px">${item.phone0}</div>
									<div style="margin:10px 0 10px 115px;width:60%;"><em class="star">* </em>地址：${item.addr}</div>
								</c:if>
								<c:if test="${not empty(item.phone1)}">

									<div style="padding-top:27px;margin-left:115px;"><em class="star">* </em>${item.pageName}</div>
									<div style="float:left;margin-top:10px;margin-left:36px; "><img src="${ctx }/images/seller/news/phone.png"></div>
									<div style="margin-top:10px; margin-left:145px; ">${item.phone0}</div>
									<div style="float:left;margin-top:10px;margin-left:36px;  "><img src="${ctx }/images/seller/news/phone.png"></div>
									<div style="margin-top:10px; margin-left:145px; ">${item.phone1}</div>
									<div style="margin:10px 0 10px 115px;width:60%;"><em class="star">*</em>地址：${item.addr}</div>

									<%-- <div style="margin-left:115px;padding-top:27px;"><em class="star">* </em>${item.pageName}</div>
									<div style="float:left;margin-top:10px; margin-left:36px; "><img src="${ctx }/images/seller/news/phone.png"></div>
									<div style="margin-top:8px; margin-left:145px; ">${item.phone0}</div>
									<div style="float:left;margin-top:8px; margin-left:-12px; "><img src="${ctx }/images/seller/news/phone.png"></div>
									<div style="margin-top:10px; margin-left:145px; ">${item.phone1}</div>
									<div style="margin-left:115px;margin-top:10px;width:60%;"><em class="star">*</em>地址：${item.addr}</div> --%>

								</c:if>
							</div>
						</td>
				</c:forEach>
				</c:if>
			</c:if>
			</tr>
			</thead>
		</table>
	</div>
	<div style="overflow: hidden;">
		<div style="float: right; margin-right: 10px; margin-top: 48px">
			<div style="float: left;">
				<ul class="footer_ul">
					<c:if test="${yellowPage.hasPreviousPage }">
						<li onclick="gotoPage(${currentPage-1 });"><a
							style="color: #37CED4">&lt;&lt;</a></li>
					</c:if>
					<c:if test="${yellowPage.firstPage > 1}">
						<li onclick="gotoPage(1);"
							style="border: 1px solid #9A9A9A;"><a>1</a></li>
						<c:if test="${yellowPage.firstPage > 2}">
                      		...
                      	</c:if>
					</c:if>
					<c:forEach items="${yellowPage.navigatepageNums }" var="page">
						<li onclick="gotoPage(${page });"
							class="<c:if test="${currentPage == page }">active</c:if>"
							style="border: 1px solid #9A9A9A;"><a>${page}</a></li>
					</c:forEach>
					<c:if test="${yellowPage.lastPage < yellowPage.pages}">
						<c:if test="${yellowPage.firstPage < yellowPage.pages - 1}">
                      		...
                      	</c:if>
						<li onclick="gotoPage(${yellowPage.pages});"
							style="border: 1px solid #9A9A9A;"><a>${yellowPage.pages}</a>
						</li>
					</c:if>
					<c:if test="${yellowPage.hasNextPage }">
						<li><a onclick="gotoPage(${currentPage+1});"
							style="color: #37CED4">&gt;&gt;</a></li>
					</c:if>
				</ul>
			</div>
			<div style="float: left; height: 28px;line-height: 28px;">
				<span style="color: #9A9A9A;">跳转到</span> 
				<input class="inputclass" id="pageNo" onkeydown="if(event.keyCode==13){event.keyCode=0;return false;}"
					type="text" value="${currentPage }" style="width: 26px; height: 26px" onkeyup = "checInputNum(this)"> 
				<span style="color: #9A9A9A;">页</span> 
				<span class="buttonclass" id="J_JumpTo" onclick="gotoYellowPage(null);"> <a>GO</a></span>
			</div>
		</div>
	</div>
</section>
<script type="text/javascript">
		var ctx = '${ctx}';
		setCtx(ctx);
</script>
	<!-- 解决ie 6 7 8 9不能显示placeholder的问题 -->
	<script src="${ctx}/js/lib/jquery.JPlaceholder.js"></script>